Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wip(session-recordings): store session recordings to S3 #10142

Closed
wants to merge 24 commits into from

Conversation

hazzadous
Copy link
Contributor

@hazzadous hazzadous commented Jun 6, 2022

This change does a number of things:

  1. Adds a Kafka Connect cluster to dev, which includes the Confluent
    S3 Sink
    Connector
    .
    This connector allows for pushing data to S3 from a Kafka Topic,
    partitioned by some criteria. In this case we partition by
    team_id,session_id,window_id. This should be scaleable although some
    testing would be useful here.
  2. Rather than retrieving the data from ClickHouse, we can get it
    directly from S3.
  3. Unpack and uncompress the nested rrweb event. Not really necessary
    but a blob of base64 encoded gzipped data isn't very friendly.
  4. Adds a script to create the Connector.

TODO: This doesn't:

  1. add Kafka Connect to Helm
  2. offload to MSK Connect deployment in production
  3. remove the pushing of messages to ClickHouse. We still want a place
    to push data to use to calculate the duration of the sessions.

Refers to #2142

Problem

Changes

👉 Stay up-to-date with PostHog coding conventions for a smoother review.

How did you test this code?

This change does a number of things:

 1. Adds a Kafka Connect cluster to dev, which includes the [Confluent
    S3 Sink
    Connector](https://docs.confluent.io/kafka-connect-s3-sink/current/overview.html).
    This connector allows for pushing data to S3 from a Kafka Topic,
    partitioned by some criteria. In this case we partition by
    team_id,session_id,window_id. This should be scaleable although some
    testing would be useful here.
 2. Rather than retrieving the data from ClickHouse, we can get it
    directly from S3.
 3. Unpack and uncompress the nested rrweb event. Not really necessary
    but a blob of base64 encoded gzipped data isn't very friendly.
 4. Adds a script to create the Connector.

TODO: This doesn't:

 1. add Kafka Connect to Helm
 2. offload to MSK Connect deployment in production
 3. remove the pushing of messages to ClickHouse. We still want a place
    to push data to use to calculate the duration of the sessions.
@hazzadous hazzadous marked this pull request as draft June 6, 2022 06:07
@posthog-bot
Copy link
Contributor

This PR hasn't seen activity in a week! Should it be merged, closed, or further worked on? If you want to keep it open, post a comment or remove the stale label – otherwise this will be closed in another week.

@posthog-bot
Copy link
Contributor

This PR was closed due to 2 weeks of inactivity. Feel free to reopen it if still relevant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants